 #{extends 'main.html' /}
<script type="text/javascript">
	adInvites.inviteToJoinOrg()}', {
			'orgname' : $("select[id$='mydropdown'] :selected").text(),
			'body' : document.getElementById("bodyo	finvitation").value,
			'devusername' : document.getElementById("usertoinvite").value
		}, function(data) {
			alert(data.res);
		}, 'json')
		$('#invite_buttton').hide('slow');
	}
	function closeFancyboxAndRedirectToUrl(url) {
		$.fancybox.close();
		// window.location = url;
		alert("ASD");
	}

	function inn() {
		$.getJSON('@{OrganizationLe
</script>
<h1>hello ${loggedInUserName}</h1>
<div id="inviteIdeadev">
	#{ifnot org}
	<p>You dont! manage any organazations !</p>
	#{/ifnot} <select name="mydropdown" id="mydropdown"> #{list
		items:org, as: 'task' }
		<option id="${task.id}" value="${task.name}">${task.name}</option>
	</select> #{/list}
	<p>
		Invite: <input type="text" id="usertoinvite" />
	</p>
	<p>Attach a msg :</p>
	<p>
		<textarea id="bodyofinvitation" class="wsite-form-input" name="msg"
			style="width: 300px; height: 200px"></textarea>
	</p>
	<p>
		<a href="#" id="invite_buttton" onclick="inn()">Invite !</a>
	</p>
</div>